package com.future.mayi.widget;

import android.content.Context;
import android.support.annotation.Nullable;
import android.util.AttributeSet;
import android.view.View;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.TextView;

import com.future.mayi.R;

import butterknife.BindView;

public class IndexHeadFourView extends LinearLayout implements View.OnClickListener {
    @BindView(R.id.tv_title_one)
    TextView tvTitleOne;
    @BindView(R.id.tv_sub_title_one)
    TextView tvSubTitleOne;
    @BindView(R.id.iv_img_one)
    ImageView ivImgOne;
    @BindView(R.id.iv_img_two)
    ImageView ivImgTwo;
    @BindView(R.id.tv_title_two)
    TextView tvTitleTwo;
    @BindView(R.id.tv_sub_title_two)
    TextView tvSubTitleTwo;
    @BindView(R.id.iv_img_three)
    ImageView ivImgThree;
    @BindView(R.id.tv_title_three)
    TextView tvTitleThree;
    @BindView(R.id.tv_sub_title_three)
    TextView tvSubTitleThree;

    @BindView(R.id.iv_img_four)
    ImageView ivImgFour;
    @BindView(R.id.tv_title_four)
    TextView tvTitleFour;
    @BindView(R.id.tv_sub_title_four)
    TextView tvSubTitleFour;


    private Context mContext;

    public IndexHeadFourView(Context context) {
        super(context);
        init(context);
    }

    public IndexHeadFourView(Context context, @Nullable AttributeSet attrs) {
        super(context, attrs);
    }

    public IndexHeadFourView(Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
        super(context, attrs, defStyleAttr);
    }

    private void init(Context context) {
        mContext = context;
        View.inflate(context, R.layout.layout_index_head_four_item, this);


        tvTitleOne = (TextView) findViewById(R.id.tv_title_one);
        tvSubTitleOne = (TextView) findViewById(R.id.tv_sub_title_one);

        tvTitleTwo = (TextView) findViewById(R.id.tv_title_two);
        tvSubTitleTwo = (TextView) findViewById(R.id.tv_sub_title_two);

        tvTitleThree = (TextView) findViewById(R.id.tv_title_three);
        tvSubTitleThree = (TextView) findViewById(R.id.tv_sub_title_three);


        tvTitleFour = (TextView) findViewById(R.id.tv_title_four);
        tvSubTitleFour = (TextView) findViewById(R.id.tv_sub_title_four);


        ivImgOne = (ImageView) findViewById(R.id.iv_img_one);
        ivImgTwo = (ImageView) findViewById(R.id.iv_img_two);
        ivImgThree = (ImageView) findViewById(R.id.iv_img_three);
        ivImgFour = (ImageView) findViewById(R.id.iv_img_four);


        findViewById(R.id.ll_one).setOnClickListener(this);
        findViewById(R.id.ll_two).setOnClickListener(this);
        findViewById(R.id.ll_three).setOnClickListener(this);
        findViewById(R.id.ll_four).setOnClickListener(this);
    }

    @Override
    public void onClick(View v) {
        switch (v.getId()) {
            case R.id.ll_one:
                break;
            case R.id.ll_two:
                break;
            case R.id.ll_three:
                break;
            case R.id.ll_four:
                break;
        }
    }
}
